﻿function returnImg(url) {

    window.returnValue = url;
    window.close();
}



function loadBarDisplay(form) {
    var imgval = $("#uploadFile").val();
    if (!IsImage(imgval, false)) {
        alert("你选择的图片格式不支持");
        $("#uploadFile").val('');
        return false;
    }


    var x, y;
    x = document.body.clientWidth;
    y = document.body.clientHeight;

    var top = (y / 2) - 50;
    var left = (x / 2) - 150;
    if (left <= 0) left = 10;


    //loader.style.left = left + "px"
    //loader.style.top = top + "px";
    $("#loader").css({ 'left': left, 'top': top });
    $("#loader").show();
    $(".table_form").hide();
    form.submit();
    return;

}

function loadBarUnDisplay() {
    $("#loader").hide();
    $(".table_form").show();

}